home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
TPUG - Toronto PET Users Group
/
TPUG Users Group CD
/
TPUG Users Group CD.iso
/
AMIGA
/
(A)D
/
(A)D5.ADF
/
NSD.S
< prev
next >
Wrap
Text File
|
1988-04-01
|
58KB
|
3,455 lines
;***********************************************
;* PARSEC SOFTWARE *
;* *
;* NORTH SEA DEMO 07.08.88 *
;* English Version *
;***********************************************
jsr open_screen
jsr planes_init
jsr startcopper
move.l #logo_name,filename
jsr printpicture
; jsr protection
jsr loadsound
move.l #bobfilename1,d7
jsr loadbobs
move.l d6,bobdata1
;jsr startcopper
jsr opstart
move.w #$8400,$dff096 ;blitter
; bra animer4
;********* Start animering 1 ************
animer1:
move.l #baggrund1,filename
jsr printpicture
; jsr protection
move.b #0,effektnr
move.b #0,slut
jsr kanal0
move.b #1,effektnr
move.b #0,slut
jsr kanal1
move.l #17,cycle_1
move.l #3,cycle_a1
move.l #300,cycle_h1
move.l #24,cycle_2
move.l #5,cycle_a2
move.l #300,cycle_h2
move.l #30,cycle_3
move.l #1,cycle_a3
move.l #400,cycle_h3
move.w #1000,d0
jsr pause
move.w #45,bobX2
move.w #90,bobY2
move.b #45,bob_nr2
move.b #46,bob_nr1
move.b #46,bob_nr3
jsr print_bob
move.w #3000,d0
jsr pause
;(noise)
move.b #2,effektnr
move.b #1,slut
jsr kanal2
move.b #46,bob_nr2
jsr print_bob
move.w #1000,d0
jsr pause
;(calling)
move.b #3,effektnr
jsr kanal2
move.w #55,bobX2
move.b #42,bob_nr2
jsr print_bob
move.w #3000,d0
jsr pause
;(calling)
move.b #3,effektnr
jsr kanal2
move.b #46,bob_nr2
jsr print_bob
move.w #1000,d0
jsr pause
move.w #85,bobX2
move.b #43,bob_nr2
jsr print_bob
move.w #1500,d0
jsr pause
;(noise)
move.b #2,effektnr
jsr kanal2
move.w #2000,d0
jsr pause
;(do you)
move.b #4,effektnr
jsr kanal2
move.b #46,bob_nr2
jsr print_bob
move.w #1000,d0
jsr pause
move.w #35,bobX2
move.b #44,bob_nr2
jsr print_bob
move.w #3000,d0
jsr pause
move.b #46,bob_nr2
jsr print_bob
move.w #1000,d0
jsr pause
;(noise)
move.b #2,effektnr
jsr kanal2
move.w #65,bobX2
move.b #41,bob_nr2
jsr print_bob
move.w #2000,d0
jsr pause
clr.l bob_ON1
clr.l bob_ON2
clr.l bob_ON3
bra animer2
; billed beskyttelse
cks1: dc.l $7530E8C0 ; logo
dc.l $0d597ca2 ; jims_plat
dc.l $ae30d958 ; plat2
dc.l $cfa22f07 ; terrorist
dc.l $e0618dff ; antiterror2
dc.l $43a88653 ; solnedgang
dc.l $5ca9c3b2 ; havsn0d
align 4
protection:
move.w #5,Toptal2
move.l #cks1,a0
add.l gembit,a0
move.l (a0),checksum
add.l #4,gembit
clr.l d2
move.l #Bitplanes,a5
someloop2:
move.l (a5),a4
move.w #2000,Toptal
someloop:
add.l (a4),d2
add.l #4,a4
sub.w #1,Toptal
bne someloop
add.l #4,a5
sub.w #1,Toptal2
bne someloop2
cmp.l checksum,d2
bne delete
rts
Toptal: dc.w 2000
Toptal2:dc.w 5
align 4
Gembit: dc.l 0
checksum: dc.l 0
align 4
;********* Start animering 2 ************
animer2:
move.l #baggrund2,filename
jsr printpicture
; jsr protection
move.b #0,effektnr
move.w #0,vol0
move.b #1,slut
jsr kanal0
;(heli)
move.b #1,effektnr
move.w #40,vol1
move.w #800,freq1
move.b #0,slut
jsr kanal1
move.l #20,cycle_1
move.l #3,cycle_a1
move.l #150,cycle_h1
move.l #0,cycle_2
move.l #0,cycle_3
;1
move.b #4,bob_nr3
move.w #40,bobX3
move.w #140,bobY3
move.b #0,bob_nr2
move.w #160,bobX2
move.w #130,bobY2
move.b #10,bob_nr1
move.w #80,bobX1
move.w #132,bobY1
jsr print_bob
move.w #46,bobX1
move.w #117,bobY1
move.b #30,bob_nr1
jsr print_bob
move.l #200,d0
jsr pause
;(skrig2)
move.b #8,effektnr
move.b #1,slut
jsr kanal2
move.l #1000,d0
jsr pause
;2
;(maskin)
move.b #7,effektnr
move.b #1,slut
jsr kanal0
move.w #80,bobX1
move.w #132,bobY1
move.b #11,bob_nr1
jsr print_bob ;Maskinpistol
move.l #100,d0 ;starter
jsr pause
;3
move.b #10,bob_nr1
move.b #5,bob_nr3
jsr print_bob
move.l #100,d0
jsr pause
;4
move.b #11,bob_nr1
jsr print_bob
move.l #100,d0
jsr pause
;5
move.b #10,bob_nr1
move.w #41,bobX3
move.b #12,bob_nr3
jsr print_bob
move.l #100,d0
jsr pause
;6
move.b #1,bob_nr2
move.w #160,bobX2
move.w #131,bobY2
move.b #11,bob_nr1
jsr print_bob
move.l #100,d0
jsr pause
;7
move.b #10,bob_nr1
move.w #50,bobX3
move.b #6,bob_nr3
jsr print_bob
move.l #100,d0
jsr pause
;7,5
move.b #2,bob_nr2
move.b #11,bob_nr1
jsr print_bob
move.l #100,d0
jsr pause
;8
move.b #10,bob_nr1
move.b #7,bob_nr3
jsr print_bob
move.w #46,bobX1
move.w #117,bobY1
move.b #31,bob_nr1
jsr print_bob
move.w #100,d0
jsr pause
;9
;(pistol2)
move.b #6,effektnr
move.b #1,slut
jsr kanal3
move.w #80,bobX1
move.w #132,bobY1
move.b #11,bob_nr1
move.b #3,bob_nr2
move.w #160,bobX2
move.w #132,bobY2
jsr print_bob
move.w #46,bobX1
move.w #117,bobY1
move.b #32,bob_nr1
jsr print_bob
move.w #100,d0
jsr pause
;10
move.w #51,bobX3
move.b #13,bob_nr3
move.b #33,bob_nr1
jsr print_bob
move.w #80,bobX1
move.w #132,bobY1
move.b #10,bob_nr1
jsr print_bob ;Maskinpistol
move.w #200,d0 ;slutter
jsr pause
;11
;(pistol2)
move.b #6,effektnr
jsr kanal3
move.w #60,bobX3
move.b #4,bob_nr3
move.b #14,bob_nr2
move.w #46,bobX1
move.w #117,bobY1
move.b #34,bob_nr1
jsr print_bob
move.w #200,d0
jsr pause
;12
move.b #5,bob_nr3
move.b #15,bob_nr2
move.b #35,bob_nr1
jsr print_bob
move.w #200,d0
jsr pause
;13
move.w #61,bobX3
move.b #12,bob_nr3
move.b #16,bob_nr2
jsr print_bob
move.w #200,d0
jsr pause
;14
move.w #70,bobX3
move.b #6,bob_nr3
move.b #17,bob_nr2
jsr print_bob
move.w #200,d0
jsr pause
;15
move.w #68,bobX3
move.w #141,bobY3
move.b #8,bob_nr3
move.b #18,bob_nr2
jsr print_bob
move.w #200,d0
jsr pause
;16
;(skrig)
move.b #5,effektnr
move.b #1,slut
jsr kanal0
move.b #6,effektnr
move.b #1,slut
jsr kanal2
move.b #9,bob_nr3
move.w #160,bobX1
move.w #155,bobY1
move.b #19,bob_nr1
move.w #185,bobX2
move.b #20,bob_nr2
jsr print_bob ;1.Pumpgun
move.w #100,d0
jsr pause
;17
move.b #8,bob_nr3
jsr print_bob
move.w #100,d0
jsr pause
;17,1
move.w #190,bobX2
move.b #21,bob_nr2
jsr print_bob
move.w #150,d0
jsr pause
;17,2
move.w #195,bobX2
move.b #23,bob_nr2
jsr print_bob
move.w #150,d0
jsr pause
;17,3
move.w #200,bobX2
move.b #22,bob_nr2
jsr print_bob
move.w #150,d0
jsr pause
;17,4
move.w #205,bobX2
move.b #20,bob_nr2
jsr print_bob
move.w #150,d0
jsr pause
;17,5
move.w #210,bobX2
move.b #21,bob_nr2
jsr print_bob
move.w #150,d0
jsr pause
;17,6
move.w #215,bobX2
move.b #23,bob_nr2
jsr print_bob
move.w #150,d0
jsr pause
;17,7
move.w #220,bobX2
move.b #22,bob_nr2
jsr print_bob
move.w #150,d0
jsr pause
;18
;(pistol2)
move.b #6,effektnr
jsr kanal2
move.b #24,bob_nr2
move.b #9,bob_nr3
jsr print_bob ;2.Pumpgun
move.w #100,d0
jsr pause
;19
move.b #8,bob_nr3
jsr print_bob
move.w #100,d0
jsr pause
;19,5
move.w #133,bobY2
move.b #25,bob_nr2
jsr print_bob
move.w #200,d0
jsr pause
;19,6
move.w #136,bobY2
move.b #26,bob_nr2
jsr print_bob
move.w #200,d0
jsr pause
;19,7
move.w #141,bobY2
move.b #27,bob_nr2
jsr print_bob
move.w #200,d0
jsr pause
;19,8
move.w #147,bobY2
move.b #28,bob_nr2
jsr print_bob
move.w #200,d0
jsr pause
;19,9
move.w #151,bobY2
move.b #29,bob_nr2
jsr print_bob
move.w #200,d0
jsr pause
;20
move.w #140,bobY3
move.w #70,bobX3
move.b #5,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;30
move.w #71,bobX3
move.b #12,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;31
move.w #80,bobX3
move.b #6,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;32
move.b #7,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;33
move.w #81,bobX3
move.b #13,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;34
move.w #90,bobX3
move.b #4,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;34,1
move.b #5,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;34,2
move.w #91,bobX3
move.b #12,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;34,3
move.w #100,bobX3
move.b #6,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;34,4
move.w #98,bobX3
move.w #141,bobY3
move.b #8,bob_nr3
jsr print_bob
move.w #400,d0
jsr pause
;35,5
;(pistol2)
move.b #6,effektnr
jsr kanal2
move.b #9,bob_nr3
jsr print_bob ;3.Pumpgun
move.w #100,d0
jsr pause
;35
move.b #8,bob_nr3
move.w #266,bobX1
move.w #140,bobY1
move.b #36,bob_nr1
jsr print_bob
move.w #200,d0
jsr pause
;36
move.b #37,bob_nr1
jsr print_bob
move.w #300,d0
jsr pause
;37
move.w #265,bobX1
move.b #38,bob_nr1
jsr print_bob
move.w #300,d0
jsr pause
;38
move.w #248,bobX1
move.b #39,bob_nr1
jsr print_bob
move.w #300,d0
jsr pause
;39
move.b #40,bob_nr1
jsr print_bob
move.b #1,effektnr
move.b #1,slut
move.w #0,vol1
jsr kanal1
move.w #1000,d0
jsr pause
clr.l bob_ON1
clr.l bob_ON2
clr.l bob_ON3
;****** Start animering 3 ******
animer3:
move.l #baggrund3,filename
jsr printpicture
; jsr protection
move.l #0,cycle_1
move.w #700,d0
jsr pause
;0,1
;(maskin)
move.b #7,effektnr
move.b #1,slut
move.w #360,freq7
jsr kanal0
move.w #120,bobX2
move.w #65,bobY2
move.b #55,bob_nr2
move.b #46,bob_nr1
move.b #46,bob_nr3
jsr print_bob
move.w #100,d0
jsr pause
;0,2
move.b #46,bob_nr2
jsr print_bob
move.w #100,d0
jsr pause
;0,3
move.b #56,bob_nr2
jsr print_bob
move.w #100,d0
jsr pause
;0,4
move.b #46,bob_nr2
jsr print_bob
move.w #100,d0
jsr pause
;1
move.w #110,bobX1
move.w #36,bobY1
move.b #47,bob_nr1
jsr print_bob
move.w #130,bobX2
move.b #55,bob_nr2
move.w #75,bobY1
move.b #48,bob_nr1
jsr print_bob ;1.bob
move.w #100,d0
jsr pause
;1,1
move.b #46,bob_nr2
jsr print_bob
move.w #100,d0
jsr pause
;1,2
move.b #57,bob_nr2
jsr print_bob
move.w #100,d0
jsr pause
;1,3
move.b #46,bob_nr2
jsr print_bob
move.w #100,d0
jsr pause
;2
move.w #140,bobX2
move.b #56,bob_nr2
move.w #36,bobY1
move.b #49,bob_nr1
jsr print_bob
move.w #75,bobY1
move.b #50,bob_nr1
jsr print_bob ;2.bob
move.w #100,d0
jsr pause
;2,1
move.b #46,bob_nr2
jsr print_bob
move.w #100,d0
jsr pause
;2,2
move.b #57,bob_nr2
jsr print_bob
move.w #100,d0
jsr pause
;2,3
move.b #46,bob_nr2
jsr print_bob
move.w #100,d0
jsr pause
;3
move.w #36,bobY1
move.b #47,bob_nr1
jsr print_bob
move.w #75,bobY1
move.b #48,bob_nr1
jsr print_bob ;1.bob
move.w #300,d0
jsr pause
;4
move.w #36,bobY1
move.b #51,bob_nr1
jsr print_bob
move.w #75,bobY1
move.b #52,bob_nr1
jsr print_bob ;3.bob
move.w #300,d0
jsr pause
;5
;(maskin)
move.b #7,effektnr
move.b #1,slut
jsr kanal2
move.w #36,bobY1
move.b #53,bob_nr1
jsr print_bob
move.w #75,bobY1
move.b #54,bob_nr1
move.w #110,bobX2
move.b #55,bob_nr2
jsr print_bob ;4.bob
move.w #100,d0
jsr pause
;5,1
move.b #46,bob_nr2
jsr print_bob
move.w #100,d0
jsr pause
;5,2
move.b #56,bob_nr2
jsr print_bob
move.w #100,d0
jsr pause
;5,3
move.b #46,bob_nr2
jsr print_bob
move.w #100,d0
jsr pause
;6
move.w #36,bobY1
move.b #51,bob_nr1
jsr print_bob
move.w #75,bobY1
move.b #52,bob_nr1
move.w #120,bobX2
move.b #55,bob_nr2
jsr print_bob ;3.bob
move.w #100,d0
jsr pause
;6,1
move.b #46,bob_nr2
jsr print_bob
move.w #100,d0
jsr pause
;6,2
move.b #57,bob_nr2
jsr print_bob
move.w #100,d0
jsr pause
;6,3
move.b #46,bob_nr2
jsr print_bob
move.w #100,d0
jsr pause
;7
move.w #36,bobY1
move.b #47,bob_nr1
jsr print_bob
move.w #75,bobY1
move.b #48,bob_nr1
move.w #130,bobX2
move.b #56,bob_nr2
jsr print_bob ;1.bob
move.w #100,d0
jsr pause
;7,1
move.b #46,bob_nr2
jsr print_bob
move.w #100,d0
jsr pause
;7,2
move.b #57,bob_nr2
jsr print_bob
move.w #100,d0
jsr pause
;7,3
move.w #36,bobY1
move.b #51,bob_nr1
jsr print_bob
move.w #75,bobY1
move.b #52,bob_nr1
move.w #120,bobX2
jsr print_bob ;3.bob
move.w #300,d0
jsr pause
;10
jsr sh_pic
move.w #3500,d0
jsr pause
;11
move.b #10,effektnr
move.b #1,slut
move.w #500,freq10
move.w #64,vol10
sub.l #1500,sound10
jsr kanal2
move.w #600,freq10
jsr kanal3
add.l #1500,sound10
move.b #0,beam_ON
move.w #7,bobX1
move.w #130,bobY1
move.b #58,bob_nr1
jsr print_bob
move.w #71,bobX1
move.b #59,bob_nr1
jsr print_bob
move.w #135,bobX1
move.w #141,bobY1
move.b #60,bob_nr1
jsr print_bob
move.w #199,bobX1
move.b #61,bob_nr1
jsr print_bob
move.w #263,bobX1
move.b #62,bob_nr1
jsr print_bob
;12
move.w #15,bobX1
move.w #162,bobY1
move.b #63,bob_nr1
jsr print_bob
move.w #79,bobX1
move.b #64,bob_nr1
jsr print_bob
move.w #143,bobX1
move.b #65,bob_nr1
jsr print_bob
move.w #207,bobX1
move.b #66,bob_nr1
jsr print_bob
move.w #271,bobX1
move.b #67,bob_nr1
jsr print_bob
move.w #8000,d0
jsr pause
move.b #1,beam_ON
move.b #0,effektnr
move.w #0,vol10
jsr kanal2
clr.l bob_ON1
clr.l bob_ON2
clr.l bob_ON3
;*********** Computer ************
jsr clear_screen
move.w #$f0,copcol+4
jsr skriv
;******* Start Animering 4 *******
animer4:
move.l #baggrund4,filename
jsr printpicture
; jsr protection
move.b #1,stopcheck
move.b #1,effektnr
move.b #1,slut
move.w #0,vol1
jsr kanal1
;1
;(alarm1)
move.b #11,effektnr
move.b #1,slut
jsr kanal2
move.b #46,bob_nr1
move.w #109,bobX2
move.w #117,bobY2
move.b #72,bob_nr2
move.w #77,bobX3
move.w #118,bobY3
move.b #70,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;2
move.w #120,bobX2
move.w #116,bobY2
move.b #73,bob_nr2
add.w #4,bobX3
move.b #71,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;3
move.w #124,bobX2
move.b #68,bob_nr2
move.b #72,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;4
move.b #69,bob_nr2
add.w #11,bobX3
sub.w #1,bobY3
move.b #73,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;5
move.w #135,bobX2
move.w #115,bobY2
move.b #70,bob_nr2
add.w #4,bobX3
move.b #68,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;6
move.w #139,bobX2
move.b #71,bob_nr2
move.b #69,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;7
move.b #72,bob_nr2
add.w #11,bobX3
sub.w #1,bobY3
move.b #70,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;8
move.w #150,bobX2
move.w #114,bobY2
move.b #73,bob_nr2
add.w #4,bobX3
move.b #71,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;9
move.w #154,bobX2
move.b #68,bob_nr2
move.b #72,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;10
move.b #69,bob_nr2
add.w #11,bobX3
sub.w #1,bobY3
move.b #73,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;11
move.w #165,bobX2
move.w #113,bobY2
move.b #70,bob_nr2
add.w #4,bobX3
move.b #68,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;12
move.w #169,bobX2
move.b #71,bob_nr2
move.b #69,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;13
move.b #72,bob_nr2
add.w #11,bobX3
sub.w #1,bobY3
move.b #70,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;14
move.w #180,bobX2
move.w #112,bobY2
move.b #73,bob_nr2
add.w #4,bobX3
move.b #71,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;15
;(alarm1)
move.b #11,effektnr
jsr kanal2
move.w #184,bobX2
move.b #68,bob_nr2
move.b #72,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;16
move.b #69,bob_nr2
add.w #11,bobX3
sub.w #1,bobY3
move.b #73,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;17
move.w #195,bobX2
move.w #111,bobY2
move.b #70,bob_nr2
add.w #4,bobX3
move.b #68,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;18
move.w #199,bobX2
move.b #71,bob_nr2
move.b #69,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;19
move.b #72,bob_nr2
add.w #11,bobX3
sub.w #1,bobY3
move.b #70,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;20
move.w #210,bobX2
move.w #110,bobY2
move.b #73,bob_nr2
add.w #4,bobX3
move.b #71,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;21
move.w #214,bobX2
move.b #68,bob_nr2
move.b #72,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;22
move.b #69,bob_nr2
add.w #11,bobX3
sub.w #1,bobY3
move.b #73,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;23
move.w #225,bobX2
move.w #109,bobY2
move.b #70,bob_nr2
add.w #4,bobX3
move.b #68,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;24
move.w #229,bobX2
move.b #71,bob_nr2
move.b #69,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;25
move.b #72,bob_nr2
add.w #11,bobX3
sub.w #1,bobY3
move.b #70,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;26
move.w #240,bobX2
move.w #108,bobY2
move.b #73,bob_nr2
add.w #4,bobX3
move.b #71,bob_nr3
jsr print_bob
move.w #150,d0
jsr pause
;27 ;ind
move.w #244,bobX2
move.b #74,bob_nr2
move.b #72,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;28
move.w #245,bobX2
move.b #75,bob_nr2
add.w #11,bobX3
sub.w #1,bobY3
move.b #73,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;29
move.b #76,bob_nr2
add.w #4,bobX3
move.b #68,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;30
move.w #248,bobX2
move.w #104,bobY2
move.b #77,bob_nr2
move.b #69,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;31
move.w #249,bobX2
move.w #99,bobY2
move.b #78,bob_nr2
add.w #11,bobX3
sub.w #1,bobY3
move.b #70,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;32
;(alarm1)
move.b #11,effektnr
jsr kanal2
move.w #252,bobX2
move.w #96,bobY2
move.b #79,bob_nr2
add.w #4,bobX3
move.b #71,bob_nr
jsr print_bob
move.w #200,d0
jsr pause
;33
move.w #255,bobX2
move.w #90,bobY2
move.b #80,bob_nr2
move.b #72,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;34
move.w #257,bobX2
move.b #81,bob_nr2
add.w #11,bobX3
sub.w #1,bobY3
move.b #73,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;35
move.w #260,bobX2
move.w #100,bobY2
move.b #82,bob_nr2
add.w #4,bobX3
move.b #74,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;36
move.b #46,bob_nr2
add.w #1,bobX3
move.b #75,bob_nr3
jsr print_bob
move.w #100,d0
jsr pause
;37
move.b #76,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;38
add.w #3,bobX3
sub.w #4,bobY3
move.b #77,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;39
add.w #1,bobX3
sub.w #5,bobY3
move.b #78,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;40
add.w #3,bobX3
sub.w #3,bobY3
move.b #79,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;41
add.w #3,bobX3
sub.w #6,bobY3
move.b #80,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;42
add.w #2,bobX3
move.b #81,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;43
add.w #3,bobX3
add.w #10,bobY3
move.b #82,bob_nr3
jsr print_bob
move.w #200,d0
jsr pause
;44
move.b #46,bob_nr3
jsr print_bob
;45
;(alarm1)
move.b #11,effektnr
jsr kanal2
move.w #3000,d0
jsr pause
;(noise)
move.b #0,effektnr
move.b #0,slut
move.w #21,vol0
move.w #550,freq0
jsr kanal3
;(heli)
move.b #1,effektnr
move.w #800,freq1
move.w #0,vol1
jsr kanal2
move.l #20,cycle_1
move.l #3,cycle_a1
move.l #500,cycle_h1
move.w #63,animtael
anilo1: sub.l #5,cycle_h1
sub.w #3,freq0
move.w freq0,$dff0d6
sub.w #2,freq1
move.w freq1,$dff0c6
move.w vol1,d0
add.b #1,d0
move.b d0,$dff0c8
move.w d0,vol1
move.w #285,d0
jsr pause
sub.w #1,animtael
bne anilo1
move.b #64,d0
move.b d0,$dff0c8
move.w #6000,d0
jsr pause
clr.l bob_ON1
clr.l bob_ON2
clr.l bob_ON3
jsr clear_screen
move.b #0,stopcheck
move.b #0,effektnr
move.b #1,slut
move.w #2,vol0
jsr kanal3
move.b #1,effektnr
move.w #0,vol1
jsr kanal2
jsr kanal1
jsr kanal0
jsr efree
;******* Start animering 5 ********
animer5:
move.l #baggrund5,filename
jsr printpicture
; jsr protection
jsr opstart
move.b #1,stopcheck
move.w #$b400,beamsted
move.l #8,cycle_1
move.l #3,cycle_a1
move.l #400,cycle_h1
move.l #12,cycle_2
move.l #3,cycle_a2
move.l #200,cycle_h2
move.l #16,cycle_3
move.l #3,cycle_a3
move.l #200,cycle_h3
;1
;(heli)
move.b #1,effektnr
move.b #0,slut
move.w #30,vol1
move.w #550,freq1
jsr kanal1
move.w #0,bobX2
move.w #80,bobY2
move.b #83,bob_nr2
move.w #140,bobX3
move.w #76,bobY3
move.b #83,bob_nr3
move.b #46,bob_nr1
jsr print_bob
move.w #200,d0
jsr pause
;2
move.w #50,animtael
anilo2: add.w #2,bobX2
add.w #1,bobX3
jsr print_bob
move.w #200,d0
jsr pause
sub.w #1,animtael
bne anilo2
;3
clr.l bob_ON1
clr.l bob_ON2
clr.l bob_ON3
move.w #185,bobX1
move.w #75,bobY1
move.b #55,bob_nr1
jsr print_bob
move.w #200,d0
jsr pause
;4
move.w #0,bobY2
move.b #46,bob_nr2
move.w #0,bobY3
move.b #46,bob_nr3
jsr print_bob
move.w #52,animtael
move.l #bang,bangcount
;(bom1)
move.b #13,effektnr
move.b #1,slut
jsr kanal3
;(bom1)
move.w #400,freq13
jsr kanal2
move.b #0,beam_ON
bang1: move.l bangcount,a0
move.w (a0),bobX1
add.l #2,a0
move.w (a0),bobY1
add.l #2,a0
move.w (a0),d0
add.l #2,a0
move.b d0,bob_nr1
move.l a0,bangcount
jsr print_bob
sub.w #1,animtael
bne bang1
move.b #1,beam_ON
;(bom1)
move.b #13,effektnr
move.w #300,freq13
jsr kanal3
move.w #1000,d0
jsr pause
clr.l bob_ON1
clr.l bob_ON2
clr.l bob_ON3
move.b #0,stopcheck
jsr clear_screen
move.b #1,slut
move.b #1,effektnr
move.w #0,vol1
jsr kanal0
jsr kanal1
jsr eopen_dos
move.l #file12,efilename
move.l #21174,echunk_size
jsr eopen_file
move.l epic_buf,sound12
;****** Start animering 6 *******
animer6:
move.l #baggrund6,filename
jsr printpicture
; jsr protection
;(storm1)
move.b #12,effektnr
move.b #0,slut
jsr kanal0
move.l #16,cycle_1
move.l #7,cycle_a1
move.l #600,cycle_h1
move.l #24,cycle_2
move.l #7,cycle_a2
move.l #600,cycle_h2
move.l #8,cycle_3
move.l #7,cycle_a3
move.l #600,cycle_h3
move.w #5,animtael
havlo1:
;(storm1)
move.b #12,effektnr
move.w #400,freq12
jsr kanal2
move.w #149,bobX2
move.w #81,bobY2
move.b #91,bob_nr2
move.b #46,bob_nr1
move.b #46,bob_nr3
jsr print_bob
move.w #600,d0
jsr pause
move.w #151,bobX2
move.w #53,bobY2
move.b #91,bob_nr2
jsr print_bob
move.w #600,d0
jsr pause
move.w #145,bobX2
move.w #49,bobY2
move.b #90,bob_nr2
jsr print_bob
move.w #600,d0
jsr pause
move.w #147,bobX2
move.w #83,bobY2
move.b #89,bob_nr2
jsr print_bob
move.w #600,d0
jsr pause
move.w #142,bobX2
move.w #117,bobY2
move.b #89,bob_nr2
jsr print_bob
move.w #600,d0
jsr pause
move.w #142,bobX2
move.w #134,bobY2
move.b #90,bob_nr2
jsr print_bob
move.w #600,d0
jsr pause
move.w #145,bobX2
move.w #135,bobY2
move.b #91,bob_nr2
jsr print_bob
move.w #600,d0
jsr pause
move.w #148,bobX2
move.w #105,bobY2
move.b #91,bob_nr2
jsr print_bob
move.w #600,d0
jsr pause
sub.w #1,animtael
bne havlo1
clr.l bob_ON1
clr.l bob_ON2
clr.l bob_ON3
;**************************
animer7:
;(storm1)
move.w #550,$dff0a6
move.b #30,$dff0a8
move.w #500,$dff0c6
move.b #30,$dff0c8
clr.l cycle_1
clr.l cycle_2
clr.l cycle_3
jsr clear_screen
move.l #color1,color_table
jsr print_colors
move.l #text2,a0
move.b #1,tegn_farve
jsr askriv
move.w #10000,d0
jsr pause
move.b #30,d1
move.w #30,d0
stom1: sub.w #1,d0
bne stom1
move.b d1,$dff0a8
move.b d1,$dff0c8
sub.b #1,d1
beq voned
bra stom1
voned: jsr clear_screen
move.b #0,beam_ON
move.w #7,bobX1
move.w #80,bobY1
move.b #58,bob_nr1
move.w #0,bobY2
move.b #46,bob_nr2
move.w #0,bobY3
move.b #46,bob_nr3
jsr print_bob
move.w #71,bobX1
move.b #59,bob_nr1
jsr print_bob
move.w #135,bobX1
move.w #91,bobY1
move.b #60,bob_nr1
jsr print_bob
move.w #199,bobX1
move.b #61,bob_nr1
jsr print_bob
move.w #263,bobX1
move.b #62,bob_nr1
jsr print_bob
move.w #15,bobX1
move.w #112,bobY1
move.b #63,bob_nr1
jsr print_bob
move.w #79,bobX1
move.b #64,bob_nr1
jsr print_bob
move.w #143,bobX1
move.b #65,bob_nr1
jsr print_bob
move.w #207,bobX1
move.b #66,bob_nr1
jsr print_bob
move.w #271,bobX1
move.b #67,bob_nr1
jsr print_bob
move.w #4000,d0
jsr pause
move.l #text3,a0
move.b #30,tegn_farve
jsr askriv
move.w #4000,d0
jsr pause
;******* SLUT ***********
animslut:
jmp $fc0000
jsr stopcopper
jsr close_screen
; jsr efree
move.l bobdata1,d6
jsr freebobs
rts
;**********************************
delete:
jsr open_dos
move.l dos_base,a6
move.l #dname,d1
jsr -30-42(a6)
jsr 0
dname: dc.b 'bobprog2',0
align 4
;**********************************
text2:
dc.b 30,30,30,30
dc.b 0,0,0,0,0,0,0,25,15,21,0,1,18,5,0,1,12,15,14,5,30
dc.b 0,0,0,0,1,7,1,9,14,19,20,0,9,13,16,15,19,9,2,12,5,0
dc.b 15,4,4,19,30,30
dc.b 0,0,0,1,0,18,1,20,9,15,14,1,12,0,
dc.b 20,18,1,14,19,1,3,20,9,15,14,0,27,30,30
dc.b 0,0,0,15,14,5,0,12,9,6,5,0,9,14,0
dc.b 5,24,3,8,1,14,7,5,0,15,6,30
dc.b 0,0,0,0,0,0,20,8,5,0,23,15,18,12,4,0,5,3,15,14,15,13,25,30,30
dc.b 0,0,0,25,15,21,0,1,18,5,0,20,8,5,0,15,14,12,25,0
dc.b 15,14,5,0,12,5,6,20,30
dc.b 0,0,0,0,20,15,0,3,15,13,16,12,5,20,5,0,20,8,5,0
dc.b 13,9,19,19,9,15,14,30,30
dc.b 0,0,0,20,8,5,18,5,0,9,19,0,14,15,0
dc.b 20,21,18,14,9,14,7,0,2,1,3,11,31
text3:
dc.b 30,30,30,30,30,30,30,30,30
dc.b 30,30,30,30,30,30,30,30
dc.b 0,0,0,0,0,0,0,0,0
dc.b 3,15,13,9,14,7,0,19,15,15,14,0,27,31
align 4
;**********************************
askriv:
move.w #0,tegn_X
move.w #0,tegn_Y
askri4: move.b (a0),tegn_nr
beq askri1
cmp.b #30,tegn_nr
beq askri2
cmp.b #31,tegn_nr
beq askri3
sub.b #1,tegn_nr
move.l a0,askrivbuf
jsr print_bogstav
move.l askrivbuf,a0
askri1: add.w #10,tegn_X
add.l #1,a0
bra askri4
askri2: move.w #0,tegn_X
add.w #10,tegn_Y
add.l #1,a0
bra askri4
askri3: rts
askrivbuf: dc.l 0
;**********************************
color1:
dc.w 0,$880,0,0,0,0,0,0
dc.w 0,0,0,0,0,0,0,0
dc.w 0,0,0,0,0,0,0,0
dc.w 0,0,0,0,0,$444,$f00,$f50
;**********************************
bang: dc.w 180,70,84,165,75,85
dc.w 161,95,88,179,73,87
dc.w 198,81,86,184,65,84
dc.w 172,69,85,190,79,84
dc.w 170,101,88,182,75,84
dc.w 179,93,87,209,82,86
dc.w 211,75,84,218,83,86
dc.w 187,86,84,168,111,88
dc.w 174,81,84,156,106,88
dc.w 175,90,87,169,64,84
dc.w 165,79,87,186,53,84
dc.w 170,58,85,184,67,84
dc.w 205,80,86,163,52,84
dc.w 161,66,87,164,78,84
dc.w 142,101,88,192,62,84
dc.w 170,89,88,221,57,84
dc.w 204,58,85,237,70,86
dc.w 232,53,84,251,61,86
dc.w 167,66,84,223,44,84
dc.w 220,63,87,231,70,84
dc.w 212,92,88,210,52,84
dc.w 208,65,87,196,40,84
dc.w 178,48,85,198,73,84
dc.w 188,83,87,210,88,84
dc.w 188,106,88,196,58,85
dc.w 208,68,84,174,79,87
align 4
animtael: dc.l 0
bangcount: dc.l 0
;***********************
pause:
move.w d0,pauset2
pause2: move.w #110,pauset
pause1: sub.w #1,pauset
bne pause1
jsr color_cycle
jsr music
sub.w #1,pauset2
bne pause2
rts
pauset: dc.l 0
pauset2:dc.l 0
;****** Sort/Hvid ******
sh_pic:
move.w #29,d3
move.l #copcol,a0
shloop: move.w (a0),d0
move.w d0,d1
move.w d0,d2
and.l #$f,d0
and.l #$f0,d1
lsr.w #4,d1
and.l #$f00,d2
lsr.w #8,d2
add.w d1,d0
add.w d2,d0
divu #3,d0
and.l #$fff,d0
move.l d0,d1
lsl.w #4,d1
move.l d0,d2
lsl.w #8,d2
add.w d1,d0
add.w d2,d0
move.w d0,(a0)
add.l #4,a0
sub.w #1,d3
bne shloop
rts
;***** Color Cycle *****
color_cycle:
move.l cycle_1,d2
beq cych1 ;ingen cycle?
move.l cycle_a1,d3
move.l cycle_buf1,d4
bne cyclo2
move.l cycle_h1,cycle_buf1
jsr cycle
bra cych1
cyclo2: sub.l #1,cycle_buf1
cych1: move.l cycle_2,d2
beq cych2
move.l cycle_a2,d3
move.l cycle_buf2,d4
bne cyclo3
move.l cycle_h2,cycle_buf2
jsr cycle
bra cych2
cyclo3: sub.l #1,cycle_buf2
cych2: move.l cycle_3,d2
beq cych3
move.l cycle_a3,d3
move.l cycle_buf3,d4
bne cyclo4
move.l cycle_h3,cycle_buf3
jsr cycle
rts
cyclo4: sub.l #1,cycle_buf3
cych3: rts
cycle: move.l #copcol,a0
mulu #4,d2
mulu #4,d3
add.l d2,a0
move.l a0,a1
sub.l #4,a0
move.w (a1,d3),d4
cyclo1: move.w (a0,d3),(a1,d3)
sub.l #4,d3
bne cyclo1
move.w d4,(a1,d3)
rts
cycle_1: dc.l 0 ;sidste col.nr.
cycle_a1: dc.l 0 ;antal
cycle_h1: dc.l 0 ;hastighed
cycle_buf1: dc.l 0
cycle_2: dc.l 0
cycle_a2: dc.l 0
cycle_h2: dc.l 0
cycle_buf2: dc.l 0
cycle_3: dc.l 0
cycle_a3: dc.l 0
cycle_h3: dc.l 0
cycle_buf3: dc.l 0
;***********************
beregn_XY:
clr.l d0 ;Hent
move.b bob_nr,d0 ;hojde
lsl.w #1,d0 ;og bredde
move.l #HB_table,a0 ;.....
add.l d0,a0
move.b (a0),hojde
add.l #1,a0
move.b (a0),bredde
lsl.w #1,d0 ;Beregn
move.l #adr_table,a0 ;relativ adr.
add.l d0,a0 ;....
move.l (a0),d0
move.l bobdata,d1
add.l d1,d0
move.l d0,figur_adr
move.w bobX,d0 ;Hent X,Y
move.w bobY,d1 ; -
move.w d0,bobshift ;Beregn Shift
and.w #15,bobshift ; - -
lsr.w #3,d0 ;Beregn X,Y
mulu #40,d1 ; - -
add.w d0,d1 ; - -
move.l d1,XY_adr ;og store
clr.l d0 ;Beregn BobSize
clr.l d1 ;.....
move.b hojde,d0
move.b bredde,d1
lsl.w #6,d0
add.w d1,d0
move.w d0,bobsize
move.w #40,d0 ;Beregn
lsl.w #1,d1 ;Skaerm
sub.w d1,d0 ;Modulo
sub.w #2,d0 ;....
move.w d0,modulo
clr.l d0
move.b hojde,d0 ;Beregn
move.l d1,a4
mulu d1,d0 ;hojdr*bredde
move.w d0,naeste ;....
rts
;***********************
loadbobs:
move.l ExecBase,a6
move.l #$10000,d1
move.l bobdatasize,d0
jsr AllocMem(a6)
move.l d0,d6
jsr open_dos
move.l dos_base,a6
move.l d7,d1
move.l #1005,d2
jsr Open(a6)
beq out
move.l d0,file
jsr load1
out: rts
load1: move.l dos_base,a6
move.l file,d1
move.l d6,d2
move.l bobdatasize,d3
jsr Read(a6)
move.l dos_base,a6
move.l file,d1
jsr Close(a6)
rts
;**************************
freebobs:
move.l ExecBase,a6
move.l d6,a1
move.l bobdatasize,d0
jsr -30-180(a6)
rts
;**************************
print_bob:
jsr music
move.b bob_nr1,bob_nr ;Beregn X,Y 1
move.w bobX1,bobX
move.w bobY1,bobY
move.l bobdata1,bobdata
jsr beregn_XY
move.b hojde,hojde1
move.b bredde,bredde1
move.l figur_adr,figur_adr1
move.w bobshift,bobshift1
move.l XY_adr,XY_adr1
move.w bobsize,bobsize1
move.w modulo,modulo1
move.w naeste,naeste1
jsr music
move.b bob_nr2,bob_nr ;Beregn X,Y 2
move.w bobX2,bobX
move.w bobY2,bobY
move.l bobdata1,bobdata
jsr beregn_XY
move.b hojde,hojde2
move.b bredde,bredde2
move.l figur_adr,figur_adr2
move.w bobshift,bobshift2
move.l XY_adr,XY_adr2
move.w bobsize,bobsize2
move.w modulo,modulo2
move.w naeste,naeste2
jsr music
move.b bob_nr3,bob_nr
move.w bobX3,bobX
move.w bobY3,bobY
move.l bobdata1,bobdata
jsr beregn_XY
move.b hojde,hojde3
move.b bredde,bredde3
move.l figur_adr,figur_adr3
move.w bobshift,bobshift3
move.l XY_adr,XY_adr3
move.w bobsize,bobsize3
move.w modulo,modulo3
move.w naeste,naeste3
jsr music
move.l figur_adr1,d0 ;Make Mask 1
move.w bobsize1,d3
clr.l d4
move.w naeste1,d4
move.l #mask_buf1,d5
jsr make_mask
jsr music
move.l figur_adr2,d0 ;Make Mask 2
move.w bobsize2,d3
clr.l d4
move.w naeste2,d4
move.l #mask_buf2,d5
jsr make_mask
jsr music
move.l figur_adr3,d0
move.w bobsize3,d3
clr.l d4
move.w naeste3,d4
move.l #mask_buf3,d5
jsr make_mask
jsr music
move.l figur_adr1,d2 ;Bob Til Buffer 1
move.l #bob_buf1,d1
move.w bobsize1,d4
clr.l d5
move.w naeste1,d5
jsr bob_til_buffer
jsr music
move.l figur_adr2,d2 ;Bob til Buffer 2
move.l #bob_buf2,d1
move.w bobsize2,d4
clr.l d5
move.w naeste2,d5
jsr bob_til_buffer
jsr music
move.l figur_adr3,d2
move.l #bob_buf3,d1
move.w bobsize3,d4
clr.l d5
move.w naeste3,d5
jsr bob_til_buffer
cmp.b #0,beam_ON
beq beamhop
beam: move.w $dff006,d0
and.w #$ff00,d0
cmp.w beamsted,d0
bne beam
beamhop:
jsr music
move.l bobshift1,d4
move.l XY_adr1,d1
move.l #bob_buf1,d2
move.w modulo1,d6
move.w bobsize1,d0
move.l #mask_buf1,a1
jsr bob_til_skaerm
move.b #1,bob_ON1
jsr music
tst.b bob_ON2 ;Bob 2 ON ?
beq OFhop2 ;Nej - Hop
move.l gammel_XY2,d0 ;Fjern Bob 2
move.l #bag_buf2,d1
move.w G_modulo2,d6
move.w G_bobsize2,d4
jsr fjern_bob
OFhop2: move.l XY_adr2,gammel_XY2
move.w modulo2,G_modulo2
move.w bobsize2,G_bobsize2
jsr music
tst.b bob_ON3
beq OFhop3
move.l gammel_XY3,d0
move.l #bag_buf3,d1
move.w G_modulo3,d6
move.w G_bobsize3,d4
jsr fjern_bob
OFhop3: move.l XY_adr3,gammel_XY3
move.w modulo3,G_modulo3
move.w bobsize3,G_bobsize3
jsr music
move.l XY_adr2,d0 ;Save Baggrund 2
move.l #bag_buf2,d1
move.w modulo2,d6
move.w bobsize2,d4
jsr save_baggrund
jsr music
move.l XY_adr3,d0
move.l #bag_buf3,d1
move.w modulo3,d6
move.w bobsize3,d4
jsr save_baggrund
jsr music
move.l bobshift1,d4 ;Bob til skaerm 1
move.l XY_adr1,d1
move.l #bob_buf1,d2
move.w modulo1,d6
move.w bobsize1,d0
move.l #mask_buf1,a1
jsr bob_til_skaerm
jsr music
move.l bobshift2,d4 ;Bob til Skaerm 2
move.l XY_adr2,d1
move.l #bob_buf2,d2
move.w modulo2,d6
move.w bobsize2,d0
move.l #mask_buf2,a1
jsr bob_til_skaerm
move.b #1,bob_ON2
jsr music
move.l bobshift3,d4
move.l XY_adr3,d1
move.l #bob_buf3,d2
move.w modulo3,d6
move.w bobsize3,d0
move.l #mask_buf3,a1
jsr bob_til_skaerm
move.b #1,bob_ON3
rts
beamsted: dc.w $d200
align 4
;*********************************
bob_til_buffer:
move.l #4,d3 ;Antal BPlaner
lobob1: btst #14,$dff002
bne lobob1
move.l d2,$dff050 ;Sourse A adr.
move.l d1,$dff054 ;Destination adr.
move.w #0,$dff064 ;Modulo A
move.w #2,$dff066 ;Modulo D
move.l #$ffffffff,$dff044
move.w #$9f0,$dff040 ;Control 0
move.w #0,$dff042 ;Control 1
move.w d4,$dff058 ;Size
add.l d5,d2 ;Naeste bobdata
add.l #820,d1 ;Naeste buffer
dbeq d3,lobob1
rts
;****************************
bob_til_skaerm:
lsr.l #4,d4 ;til brug i
move.l d4,d7 ;Control reg 0&1
add.l #$fca,d7 ;d4=$?000 d7=$?fca
move.l #bitplanes,a0 ;1.BPlan Buffer
add.w #1,d0
move.w #4,d3 ;For loop
lobob2: btst #14,$dff002
bne lobob2
move.l (a0)+,d5 ;Hent BPlan adr.
add.l d1,d5 ;+ XY adr.
move.l a1,$dff050 ;Sourse A adr.
move.l d2,$dff04c ; - B adr.
move.l d5,$dff048 ;Sourse C adr.
move.l d5,$dff054 ;Destination adr.
move.w #0,$dff064 ;Modulo A
move.w #0,$dff062 ;Modulo B
move.w d6,$dff060 ;Modulo C
move.w d6,$dff066 ;Modulo D
move.w #$ffff,$dff044
move.w #$0,$dff046
move.w d7,$dff040 ;Control 0
move.w d4,$dff042 ;Control 1
move.w d0,$dff058 ;Size
add.l #820,d2 ;Naeste BobBuffer
dbeq d3,lobob2
move.b #1,bob_ON
rts
;*****************************
make_mask:
move.l d0,d1
add.l d4,d1
move.w #0,d7
jsr blit
add.l d4,d0
add.l d4,d0
move.l d5,d1
move.w #2,d7
jsr blit
add.l d4,d0
move.l d5,d1
move.w #2,d7
jsr blit
add.l d4,d0
move.l d5,d1
move.w #2,d7
jsr blit
rts
blit: btst #14,$dff002
bne blit
move.l d5,$dff054 ;destination
move.l d0,$dff050 ;Souse A
move.l d1,$dff04c ;Souse B
move.w #0,$dff064 ;Modulo A
move.w d7,$dff062 ;Modulo B
move.w #2,$dff066 ;Modulo D
move.w #$ffff,$dff044
move.w #$ffff,$dff046
move.w #$dfc,$dff040 ;control 0
move.w #0,$dff042 ; - 1
move.w d3,$dff058 ;size
rts
;***************************
fjern_bob:
move.l #bitplanes,a0 ;Samme som
move.w #4,d2
add.w #1,d4
lofjr: btst #14,$dff002
bne lofjr
move.l (a0)+,d3
add.l d0,d3
move.l d1,$dff050
move.l d3,$dff054
move.w #0,$dff064
move.w d6,$dff066
move.l #$ffffffff,$dff044
move.w #$9f0,$dff040
move.w #0,$dff042
move.w d4,$dff058
add.l #820,d1
dbeq d2,lofjr
rts
;***************************
save_baggrund:
move.l #bitplanes,a0 ;1.BPlan Buffer
move.l #4,d2 ;Loop taeller
add.w #1,d4
lobag: btst #14,$dff002
bne lobag
move.l (a0)+,d3 ;Hent BPlan adr.
add.l d0,d3 ;+ XY adr.
move.l d3,$dff050 ;Sourse A adr.
move.l d1,$dff054 ;Destination
move.w d6,$dff064 ;Modulo A
move.w #0,$dff066 ;Modulo B
move.l #$ffffffff,$dff044
move.w #$9f0,$dff040 ;Control 0
move.w #0,$dff042 ;Control 1
move.w d4,$dff058 ;Size
add.l #820,d1 ;Naeste Buffer
dbeq d2,lobag
rts
;***************************
; DATA FOR BOBS
;***************************
bobX: dc.w 0
bobX1: dc.w 0
bobX2: dc.w 0
bobX3: dc.w 0
bobY: dc.w 0
bobY1: dc.w 0
bobY2: dc.w 0
bobY3: dc.w 0
bobsize: dc.w 0
bobsize1: dc.w 0
G_bobsize1: dc.w 0
bobsize2: dc.w 0
G_bobsize2: dc.w 0
bobsize3: dc.w 0
G_bobsize3: dc.w 0
modulo: dc.w 0
modulo1: dc.w 0
G_modulo1: dc.w 0
modulo2: dc.w 0
G_modulo2: dc.w 0
modulo3: dc.w 0
G_modulo3: dc.w 0
hojde: dc.b 0
hojde1: dc.b 0
hojde2: dc.b 0
hojde3: dc.b 0
bredde: dc.b 0
bredde1: dc.b 0
bredde2: dc.b 0
bredde3: dc.b 0
bob_nr: dc.b 0
bob_nr1: dc.b 0
bob_nr2: dc.b 0
bob_nr3: dc.b 0
beam_ON: dc.b 1
align 4
bob_ON: dc.l 0
bob_ON1: dc.l 0
bob_ON2: dc.l 0
bob_ON3: dc.l 0
bobshift: dc.l 0
bobshift1: dc.l 0
bobshift2: dc.l 0
bobshift3: dc.l 0
bitplane1: blk.l 10,0
XY_adr: dc.l 0
XY_adr1: dc.l 0
XY_adr2: dc.l 0
XY_adr3: dc.l 0
gammel_XY: dc.l 0
gammel_XY1: dc.l 0
gammel_XY2: dc.l 0
gammel_XY3: dc.l 0
bobdata: dc.l 0
bobdata1: dc.l 0
bobdata2: dc.l 0
bobdata3: dc.l 0
figur_adr: dc.l 0
figur_adr1: dc.l 0
figur_adr2: dc.l 0
figur_adr3: dc.l 0
bobdatasize: dc.l 85284
file: dc.l 0
bobfilename1: dc.b 'northseabobs',0
align 4
bobfilename2: dc.b 'data:lee-bobs',0
align 4
naeste: dc.w 0
naeste1: dc.w 0
naeste2: dc.w 0
naeste3: dc.w 0
mask_buf1: blk.w 500,0
mask_buf2: blk.w 500,0
mask_buf3: blk.w 500,0
bob_buf1: blk.w 2100,0
bob_buf2: blk.w 2100,0
bob_buf3: blk.w 2100,0
bag_buf1: blk.w 2100,0
bag_buf2: blk.w 2100,0
bag_buf3: blk.w 2100,0
adr_table: dc.l 0,660,1280,1900,2500,2790
dc.l 3390,3680,4280,4820,5380
dc.l 5960,6540,7140,7740,8360
dc.l 8980,9910,10840,11770
dc.l 11980,12270,12560,12850
dc.l 13140,13430,13990,14490
dc.l 14890,15170,15370,15730
dc.l 16300,16870,17440,18010
dc.l 19180,20980,22780,24580
dc.l 26980,29380,31800,34440
dc.l 36420,39720,40840,40850
dc.l 42800,44750,46700,48650
dc.l 50600,52550,54500,56450
dc.l 57350,58400,59420,60620
dc.l 61820,62390,63150,63720
dc.l 64960,66200,67440,68680
dc.l 69300,70040,70780,71150
dc.l 71890,72630,73000,73370
dc.l 74110,74850,75270,75630
dc.l 76020,76410,76750,76990
dc.l 79960,81344,81974,82734
dc.l 83394,84024,84464,84824
dc.l 85284
HB_table: dc.b 33,2,31,2,31,2,30,2,29,1
dc.b 30,2,29,1,30,2,27,2,28,2
dc.b 29,2,29,2,30,2,30,2,31,2
dc.b 31,2,31,3,31,3,31,3,7,3
dc.b 29,1,29,1,29,1,29,1,29,1
dc.b 28,2,25,2,20,2,14,2,10,2
dc.b 18,2,19,3,19,3,19,3,19,3
dc.b 39,3,60,3,60,3,60,3,60,4
dc.b 60,4,22,11,22,12,22,9,22,15
dc.b 8,14,1,1,39,5,39,5,39,5
dc.b 39,5,39,5,39,5,39,5,39,5
dc.b 30,3,35,3,34,3,30,4,30,4
dc.b 19,3,19,4,19,3,31,4,31,4
dc.b 31,4,31,4,31,2,37,2,37,2
dc.b 37,1,37,2,37,2,37,1,37,1
dc.b 37,2,37,2,42,1,36,1,39,1
dc.b 39,1,34,1,24,1,33,9,46,3
dc.b 21,3,38,2,33,2,21,3,22,2
dc.b 18,2,23,2
;***************************
;offsets intuition
;
OpenIntuition =-30-0
Intuition =-30-6
CloseScreen =-30-36
OpenScreen =-30-168
PrintIText =-30-186
;
;offsets exec
;
OpenLib =-30-378
OldOpenLibrary=-30-378
CloseLibrary =-30-384
AllocMem =-30-168
FreeMem =-30-180
;
;offsets graphics (gfx)
;
LoadRGB4 =-30-162
;
;offsets DOS
;
Open =-30
Close =-30-6
Read =-30-12
Exit =-30-114
;
ExecBase =4
;
even
;************************
printpicture:
clr.l d0
move.l ExecBase,a6
lea.l gfxname,a1
jsr oldopenlibrary(a6)
move.l d0,gfxbase
move.l execbase,a6
lea intname,a1
jsr oldopenlibrary(a6)
move.l d0,a6
move.l d0,intuitionbase
;
jsr open_dos
jsr open_file
move.l #disk_buf,d2
move.l #8,d3
jsr load
move.l d2,a0
;
move.l 4(a0),d3
move.l d3,chunk_size
jsr allocate
move.l chunk_size,d3
move.l pic_buf,d2
jsr load
jsr close_file
;
jsr iff_search
;
jsr pic_print
jsr free
rts
;
; data
align 4
title: dc.b 'JIM`S BOB-CODE PROGRAM 10/11/87',0
align 4
dosname: dc.b 'dos.library',0
align 4
intname: dc.b 'intuition.library',0
align 4
gfxname: dc.b 'graphics.library',0
align 4
gfxbase: blk.l 1,0
intuitionbase: blk.l 1,0
dos_base: blk.l 1,0
;
align 4
Newscreen:
dc.w 0,0
width: dc.w 320
height: dc.w 200
depth: dc.w 5
dpen_bpen: dc.b 0,1
modes: dc.w $0,$0f
udcs: dc.l font
name: dc.l title
gadg: dc.l 0,0
font=0
screen: dc.l 0
even
;
bitplanes: blk.l 10,0
planes: blk.l 10,0
color_map: blk.w 32,0
black_color: blk.w 32,0
even
;
planes_init:
move.l screen,a0
add.l #$c0,a0
move.l #planes,a1
lea picplanes,a2
move.l #bitplanes,a3
move.w #5,d0
plane_loop:
move.w d0,d1
mulu #4,d1
move.l (a0,d1),(a2,d1)
move.l (a0,d1),(a1,d1)
move.l (a0,d1),(a3,d1)
dbra d0,plane_loop
rts
;
colors_init:
move.l cmap_chunk,a0
add.l #8,a0
move.l #color_map,a1
move.w #31,d7
co_loop1:
clr.w d0
move.b (a0)+,d0
and.b #$f0,d0
lsl.w #4,d0
move.b (a0)+,d0
and.w #$0ff0,d0
clr.w d1
move.b (a0)+,d1
lsr.b #4,d1
and.b #$0f,d1
or.b d1,d0
move.w d0,(a1)+
dbra d7,co_loop1
rts
;
pic_print:
jsr planes_init
jsr colors_init
jsr black_color_set
jsr unpacker
jsr color_set
rts
;
color_set:
move.l #color_map,color_table
jsr print_colors
rts
;
black_color_set:
move.l #black_color,color_table
jsr print_colors
rts
;
iff_search:
move.l pic_buf,a0
add.l #4,a0
move.l a0,bmhd_chunk
move.l 4(a0),d0
add.l d0,a0
add.l #8,a0
move.l a0,cmap_chunk
iff_l1:
move.l 4(a0),d0
add.l d0,a0
add.l #8,a0
move.l #'BODY',d1
cmp.l (a0),d1
bne iff_l1
move.l a0,body_chunk
move.l bmhd_chunk,a2
move.l a2,a1
add.l #16,a1
clr.w d0
move.b (a1),d0
cmp.w #6,d0
blt iff_cont
move.w #6,d0
iff_cont:
move.l #newscreen,a0
move.w d0,8(a0)
subq.w #1,d0
move.w d0,planes_num
move.l a2,a1
add.l #18,a1
move.b (a1),comp_flag
move.l a2,a1
add.l #8,a1
clr.l d0
move.w (a1)+,d0
move.w d0,width
clr.l d3
cmp.w #640,d0
blt iff_cont3
or.w #$8000,d3
iff_cont3:
move.w d0,d1
and.w #7,d1
beq iff_cont2
or.w #8,d0
iff_cont2:
divu #8,d0
move.w d0,width_bytes
clr.l d0
move.w (a1),d0
move.w d0,height
cmp.w #400,d0
blt iff_cont4
or.w #4,d3
iff_cont4:
move.w d3,modes
rts
;
unpacker:
move.l # planes,a2
move.l body_chunk,a0
add.l #4,a0
move.l (a0)+,d7
move.l a0,a3
add.l d7,a3
move.w planes_num,d2
addq.w #1,d2
;
unp_loop:
cmp.l a3,a0
bge unpack_end
;
clr.w d3
pic_loop1:
move.w d3,d4
mulu #4,d4
move.l (a2,d4),a5
jsr unpack_row
move.l a5,(a2,d4)
addq.w #1,d3
cmp.w d2,d3
blt pic_loop1
move.l bmhd_chunk,a5
andi.b #1,17(a5)
beq unp_loop
move.l #mask_dummy,a5
jsr unpack_row
bra unp_loop
unpack_row: move.l d2,-(sp)
move.w width_bytes,d2
unp_loop1: tst.w d2
beq unpack_row_end
clr.w d0
tst.w comp_flag
bne unp_comp
move.w width_bytes,d0
subq.w #1,d0
bra unp_loop2
unp_comp:
move.b (a0)+,d0
bmi packed
unp_loop2:
move.b (a0)+,(a5)+
subq.w #1,d2
dbra d0,unp_loop2
bra unp_loop1
;
packed:
neg.b d0
move.b (a0)+,d1
unp_loop3:
move.b d1,(a5)+
subq.w #1,d2
dbra d0,unp_loop3
bra unp_loop1
;
unpack_row_end:
move.l (sp)+,d2
rts
;
unpack_end:
rts
;
;
; chunk-data
;
align 4
bmhd_chunk: blk.l 1,0
cmap_chunk: blk.l 1,0
body_chunk: blk.l 1,0
planes_num: blk.w 1,0
comp_flag: blk.w 1,0
width_bytes: blk.w 1,0
;
;diskroutine for filehandling
;
open_dos:
move.l execbase,a6
lea.l dosname,a1
jsr OpenLib(a6)
move.l d0,dos_base
prg_end:
rts
;
open_file:
move.l dos_base,a6
move.l filename,d1
move.l #1005,d2
jsr Open(a6)
beq prg_end
move.l d0,bif
rts
;
load:
move.l dos_base,a6
move.l bif,d1
jsr Read(a6)
rts
;
close_file:
move.l dos_base,a6
move.l bif,d1
jsr Close(a6)
rts
;
allocate:
move.l execbase,a6
move.l #$10000,d1
move.l chunk_size,d0
jsr AllocMem(a6)
move.l d0,pic_buf
rts
;
;
free:
move.l execbase,a6
move.l pic_buf,a1
move.l chunk_size,d0
jsr FreeMem(a6)
rts
;
;
;date for filehandlimg
;
align 4
filename: dc.l 0
baggrund1: dc.b 'jims_plat',0
align 4
baggrund2: dc.b 'plat2',0
align 4
baggrund3: dc.b 'terrorist',0
align 4
baggrund4: dc.b 'antiterror2',0
align 4
baggrund5: dc.b 'solnedgang',0
align 4
baggrund6: dc.b 'havsn0d',0
align 4
logo_name: dc.b 'InnerPriseLogX',0
align 4
bif: dc.l 0
disk_buf: blk.b 10,0
align 4
pic_buf: blk.l 1,0
chunk_size: blk.l 1,0
mask_dummy: blk.b 128,0
picplanes :blk.w $200
;-end-
;********* openscreen ************
open_screen:
move.l ExecBase,a6
lea intname,a1
jsr OldOpenLibrary(a6)
move.l d0,intuitionbase
move.l intuitionbase,a6
lea.l newscreen,a0
jsr OpenScreen(a6)
move.l d0,screen
rts
********** closescreen ***********
close_screen:
move.l intuitionbase,a6
move.l screen,a0
jsr CloseScreen(a6)
rts
;********* print colors **********
print_colors:
move.w #32,d4
move.l color_table,a2
move.l #copcol,a3
gloop3: move.w (a2),d7
move.w d7,(a3)
add.l #2,a2
add.l #4,a3
sub.w #1,d4
bne gloop3
rts
color_table: dc.l 0
;********* coppertest ************
startcopper:
move.l #bitplanes,a0 ;laeg
move.w (a0),bp1h ;bitplan-adr.
add.l #2,a0 ;ind i
move.w (a0),bp1l ;copperlist
add.l #2,a0 ; -
move.w (a0),bp2h ; -
add.l #2,a0 ; -
move.w (a0),bp2l ; -
add.l #2,a0
move.w (a0),bp3h
add.l #2,a0
move.w (a0),bp3l
add.l #2,a0
move.w (a0),bp4h
add.l #2,a0
move.w (a0),bp4l
add.l #2,a0
move.w (a0),bp5h
add.l #2,a0
move.w (a0),bp5l
;jsr save
move.w #$30,$dff09a ; Stop Interrupts
move.w #$20,$dff096 ; Stop Sprite DMA
cbeam: move.w $dff006,d0
and.w #$ff00,d0
cmp.w #$fc00,d0
bne cbeam
move.l #data,$dff084 ; COPLC - adr.
move.w #1,$dff08a ; COPJMP
rts
;*********************************
stopcopper:
move.w #1,$dff088 ; COPJMP 1
move.w #$8030,$dff09a; start VB-Int.
rts
;******* copper-list ************
data: dc.w $8e ; DIWSTRT
dc.w $2c81
dc.w $90 ; DIWSTOP
dc.w $f4c1
dc.w $92 ; DFFSTRT
dc.w $38
dc.w $94 ; DFFSTOP
dc.w $d0
dc.w $e0 ; BPL1PTH
bp1h: dc.w 0
dc.w $e2 ; BPL1PTL
bp1l: dc.w 0
dc.w $e4 ; BPL2PTH
bp2h: dc.w 0
dc.w $e6 ; BPL2PTL
bp2l: dc.w 0
dc.w $e8 ; BPL3PTH
bp3h: dc.w 0
dc.w $ea ; BPL3PTL
bp3l: dc.w 0
dc.w $ec ; BPL4PTH
bp4h: dc.w 0
dc.w $ee ; BPL4PTL
bp4l: dc.w 0
dc.w $f0 ; BPL5PTH
bp5h: dc.w 0
dc.w $f2 ; BPL5PTL
bp5l: dc.w 0
dc.w $108 ;Modulo 1
dc.w 0
dc.w $10a ;Modulo 2
dc.w 0
dc.w $100 ;BPlanControl 0
dc.w $5000
dc.w $102 ; - - - - 1
dc.w 0
dc.w $104 ; - - - - 2
dc.w 0
dc.w $180
copcol: dc.w 0,$182,0,$184,0,$186,0,$188
dc.w 0,$18a,0,$18c,0,$18e
dc.w 0,$190,0,$192,0,$194,0,$196
dc.w 0,$198,0,$19a,0,$19c,0,$19e
dc.w 0,$1a0,0,$1a2,0,$1a4,0,$1a6
dc.w 0,$1a8,0,$1aa,0,$1ac,0,$1ae
dc.w 0,$1b0,0,$1b2,0,$1b4,0,$1b6
dc.w 0,$1b8,0,$1ba,0,$1bc,0,$1be
dc.w 0
dc.w $ffff,$fffe ; wait
;**************************************
save:
jsr open_dos
move.l dos_base,a6
move.l #savename,d1
move.l #1005,d2
jsr Open(a6)
move.l d0,bif
move.l dos_base,a6
move.l #bif,d1
move.l #savename,d2
move.l #20,d3
jsr -30-18(a6)
rts
savename: dc.b 'q2f5',0
align 4
;**** LOAD EFFEKT FILES ***************
loadsound:
jsr eopen_dos
move.l #file0,efilename ;file navn
move.l #5564,echunk_size ;laengde af file
jsr eopen_file
move.l epic_buf,sound0 ;start adr. pa file
jsr eopen_dos
move.l #file1,efilename
move.l #25000,echunk_size
jsr eopen_file
move.l epic_buf,sound1
jsr eopen_dos
move.l #file2,efilename
move.l #4670,echunk_size
jsr eopen_file
move.l epic_buf,sound2
jsr eopen_dos
move.l #file3,efilename
move.l #10394,echunk_size
jsr eopen_file
move.l epic_buf,sound3
jsr eopen_dos
move.l #file4,efilename
move.l #21780,echunk_size
jsr eopen_file
move.l epic_buf,sound4
jsr eopen_dos
move.l #file5,efilename
move.l #27742,echunk_size
jsr eopen_file
move.l epic_buf,sound5
jsr eopen_dos
move.l #file6,efilename
move.l #10044,echunk_size
jsr eopen_file
move.l epic_buf,sound6
jsr eopen_dos
move.l #file7,efilename
move.l #17202,echunk_size
jsr eopen_file
move.l epic_buf,sound7
jsr eopen_dos
move.l #file8,efilename
move.l #20854,echunk_size
jsr eopen_file
move.l epic_buf,sound8
jsr eopen_dos
move.l #file9,efilename
move.l #1054,echunk_size
jsr eopen_file
move.l epic_buf,sound9
jsr eopen_dos
move.l #file10,efilename
move.l #16214,echunk_size
jsr eopen_file
move.l epic_buf,sound10
add.l #1500,sound10
jsr eopen_dos
move.l #file11,efilename
move.l #5810,echunk_size
jsr eopen_file
move.l epic_buf,sound11
jsr eopen_dos
move.l #file13,efilename
move.l #25850,echunk_size
jsr eopen_file
move.l epic_buf,sound13
jsr eopen_dos
move.l #tegnfile,efilename
move.l #2000,echunk_size
jsr eopen_file
move.l epic_buf,tegn_data
rts
tegnfile: dc.b 'tegn2',0
;**** OPEN_DOS *****************
eopen_dos:
move.l execbase,a6
lea.l edosname,a1
jsr OpenLib(a6)
move.l d0,edos_base
rts
;**** OPEN_FILE ****************
eopen_file:
move.l edos_base,a6
move.l efilename,d1
move.l #1005,d2
jsr Open(a6)
beq out1
move.l d0,ebif
jsr eallocate
out1: rts
;**** LOAD *********************
eload:
move.l edos_base,a6
move.l ebif,d1
move.l echunk_size,d3
move.l epic_buf,d2
jsr Read(a6)
jsr eclose_file
rts
;**** CLOSE_FILE ***************
eclose_file:
move.l edos_base,a6
move.l ebif,d1
jsr Close(a6)
rts
;**** ALLOCATE *****************
eallocate:
move.l execbase,a6
move.l #$10000,d1
move.l echunk_size,d0
jsr AllocMem(a6)
beq out2
move.l d0,epic_buf
jsr eload
out2: rts
;**** FREE *********************
efree:
move.l execbase,a6
move.l sound4,a1
move.l #21780,d0
jsr FreeMem(a6)
rts
;**** EFFEKT FILES ********************
;
align 4
file0: dc.b 'soundfiles/noise1',0
align 4
file1: dc.b 'soundfiles/heli5',0
align 4
file2: dc.b 'soundfiles/radio4',0
align 4
file3: dc.b 'soundfiles/radio5',0
align 4
file4: dc.b 'soundfiles/radio7',0
align 4
file5: dc.b 'soundfiles/test2',0
align 4
file6: dc.b 'soundfiles/pistol2',0
align 4
file7: dc.b 'soundfiles/maskin',0
align 4
file8: dc.b 'soundfiles/skrig2',0
align 4
file9: dc.b 'soundfiles/printer',0
align 4
file10: dc.b 'soundfiles/klaus1',0
align 4
file11: dc.b 'soundfiles/alarm1',0
align 4
file12: dc.b 'soundfiles/storm1',0
align 4
file13: dc.b 'soundfiles/bom1',0
;**** VARIABLER TIL LOAD PROGRAM ****
align 4
edosname: dc.b 'dos.library',0
align 4
edos_base: blk.l 1,0
ebif: dc.l 0
edisk_buf: blk.b 10,0
align 4
efilename: dc.l 0
epic_buf: blk.l 1,0
echunk_size: dc.l 0
emask_dummy: blk.b 128,0
epicplanes :blk.w $200
;-end-
;*********************************
;* EFFEKT PROGRAM *
;*********************************
;**** KANAL 0 ********************
kanal0: clr.l d0
move.b effektnr,d0 ;sound nr.
mulu #4,d0
move.l d0,a0
move.l #sound0,a1
move.l (a0,a1),$dff0a0 ;start adr.
move.l #length0,a1
move.w (a0,a1),$dff0a4 ;length
move.l #freq0,a1
move.w (a0,a1),$dff0a6 ;rate
move.l #vol0,a1
move.w (a0,a1),$dff0a8
clr.l d0
move.b slut,d0 ;slut ja/nej
cmp.b #1,d0
beq Aslut
move.w #33281,$dff096
rts
Aslut: move.w #33281,$dff096
clr.l d0
move.b #200,d0
Aloop: cmp.b #1,d0
beq Aloop1
sub.b #1,d0
bra Aloop
Aloop1: move.w #1,$dff0a4
rts
;**** KANAL 1 *******************
kanal1: clr.l d0
move.b effektnr,d0
mulu #4,d0
move.l d0,a0
move.l #sound0,a1
move.l (a0,a1),$dff0b0
move.l #length0,a1
move.w (a0,a1),$dff0b4
move.l #freq0,a1
move.l (a0,a1),$dff0b6
move.l #vol0,a1
move.l (a0,a1),$dff0b8
clr.l d0
move.b slut,d0
cmp.b #1,d0
beq Bslut
move.w #33282,$dff096
rts
Bslut: move.w #33282,$dff096
clr.l d0
move.w #200,d0
Bloop: cmp.b #1,d0
beq Bloop1
sub.w #1,d0
bra Bloop
Bloop1: move.w #1,$dff0b4
rts
;**** KANAL 2 *********************
kanal2: clr.l d0
move.b effektnr,d0
mulu #4,d0
move.l d0,a0
move.l #sound0,a1
move.l (a0,a1),$dff0c0
move.l #length0,a1
move.w (a0,a1),$dff0c4
move.l #freq0,a1
move.w (a0,a1),$dff0c6
move.l #vol0,a1
move.w (a0,a1),$dff0c8
clr.l d0
move.b slut,d0
cmp.b #1,d0
beq Cslut
move.w #33284,$dff096
rts
Cslut: move.w #33284,$dff096
clr.l d0
move.w #200,d0
Cloop: cmp.w #1,d0
beq Cloop1
sub.w #1,d0
bra Cloop
Cloop1: move.w #1,$dff0c4
rts
;**** KANAL 3 *********************
kanal3: clr.l d0
move.b effektnr,d0
mulu #4,d0
move.l d0,a0
move.l #sound0,a1
move.l (a0,a1),$dff0d0
move.l #length0,a1
move.w (a0,a1),$dff0d4
move.l #freq0,a1
move.w (a0,a1),$dff0d6
move.l #vol0,a1
move.w (a0,a1),$dff0d8
clr.l d0
move.b slut,d0
cmp.b #1,d0
beq Dslut
move.w #33288,$dff096
rts
Dslut: move.w #33288,$dff096
clr.l d0
move.w #200,d0
Dloop: cmp.w #1,d0
beq Dloop1
sub.w #1,d0
bra Dloop
Dloop1: move.w #1,$dff0d4
rts
;**** VARIABLER TIL EFFEKT PROGRAM **
slut: dc.b 0
effektnr: dc.b 0
align 4
sound0: dc.l 0
sound1: dc.l 0
sound2: dc.l 0
sound3: dc.l 0
sound4: dc.l 0
sound5: dc.l 0
sound6: dc.l 0
sound7: dc.l 0
sound8: dc.l 0
sound9: dc.l 0
sound10: dc.l 0
sound11: dc.l 0
sound12: dc.l 0
sound13: dc.l 0
length0: dc.w 2782
dc.w 0
length1: dc.w 12500
dc.w 0
length2: dc.w 2335
dc.w 0
length3: dc.w 5197
dc.w 0
length4: dc.w 10890
dc.w 0
length5: dc.w 13871
dc.w 0
length6: dc.w 5022
dc.w 0
length7: dc.w 8601
dc.w 0
length8: dc.w 10427
dc.w 0
length9: dc.w 527
dc.w 0
length10: dc.w 8107
dc.w 0
length11: dc.w 2905
dc.w 0
length12: dc.w 10587
dc.w 0
length13: dc.w 12925
dc.w 0
freq0: dc.w 350
dc.w 0
freq1: dc.w 490
dc.w 0
freq2: dc.w 400
dc.w 0
freq3: dc.w 500
dc.w 0
freq4: dc.w 500
dc.w 0
freq5: dc.w 300
dc.w 0
freq6: dc.w 300
dc.w 0
freq7: dc.w 290
dc.w 0
freq8: dc.w 300
dc.w 0
freq9: dc.w 350
dc.w 0
freq10: dc.w 0
dc.w 0
freq11: dc.w 520
dc.w 0
freq12: dc.w 500
dc.w 0
freq13: dc.w 450
dc.w 0
vol0: dc.w 20
dc.w 0
vol1: dc.w 44
dc.w 0
vol2: dc.w 40
dc.w 0
vol3: dc.w 54
dc.w 0
vol4: dc.w 64
dc.w 0
vol5: dc.w 64
dc.w 0
vol6: dc.w 64
dc.w 0
vol7: dc.w 64
dc.w 0
vol8: dc.w 64
dc.w 0
vol9: dc.w 20
dc.w 0
vol10: dc.w 0
dc.w 0
vol11: dc.w 25
dc.w 0
vol12: dc.w 50
dc.w 0
vol13: dc.w 64
dc.w 0
;************************
;* PRINT BOGSTAVER *
;************************
skriv:
move.b #1,tegn_farve
move.w #0,tegn_X
move.w #10,tegn_Y
move.l #text,a3
skriv1: move.b (a3),tegn_nr
beq skriv4
cmp.b #31,tegn_nr ;Slut ?
beq skriv2
cmp.b #30,tegn_nr ;Ny linie ?
beq skriv3
sub.b #1,tegn_nr
jsr print_bogstav
add.l #1,a3
add.w #10,tegn_X
move.b #9,effektnr
move.b #1,slut
move.w #250,freq9
jsr kanal0
move.w #150,d0
jsr pause
bra skriv1
skriv4: add.w #10,tegn_X ;Space
add.l #1,a3
move.w #250,d0
jsr pause
bra skriv1
skriv3: move.w #0,tegn_X ;Ny linie
add.w #10,tegn_Y
add.l #1,a3
move.b #9,effektnr
move.w #150,freq9
jsr kanal0
move.w #500,d0
jsr pause
bra skriv1
skriv2: rts ;Slut
text:
dc.b 18,5,16,15,18,20,0,6,18,15,13,0
dc.b 13,9,12,9,20,1,18,25,0,8,28,17,28,30
dc.b 30
dc.b 15,14,12,25,0,20,8,18,5,5,0,8,15,21,18,19
dc.b 0,1,7,15,0,20,5,18,18,15,18,9,19,20,19,30
dc.b 1,20,20,1,3,11,5,4,0,1,14,0,15,9,12,18,9,7,0
dc.b 9,14,0,20,8,5,30
dc.b 16,5,18,19,9,1,14,0,7,21,12,6,28,30
dc.b 19,5,22,5,18,1,12,0,8,15,19,20,1,7,5,19,0
dc.b 23,5,18,5,0,20,1,11,5,14,0,1,14,4,30
dc.b 1,0,14,21,3,12,5,1,18,0,2,15,13,2,0
dc.b 23,1,19,0,16,12,1,3,5,4,0,15,14,30
dc.b 20,8,5,0,18,9,7,28,30
dc.b 18,5,17,21,5,19,20,0,16,5,18,13,9,19,19,9,15,14,0
dc.b 20,15,0,12,1,21,14,3,8,0,30
dc.b 1,20,20,1,3,11,30
dc.b 30,30,30,30,30,30
dc.b 16,5,18,13,9,19,19,9,15,14,0,7,18,1,14,20,5,4,31
align 4
;************************
print_bogstav:
move.w tegn_X,d0 ;Hent x,y
move.w tegn_Y,d1 ;& beregn
move.w d0,d2 ;adr. + shift.
and.w #15,d2 ;d2 = Shift
lsl.w #6,d2 ;(Til brug i Con.reg.)
lsl.w #6,d2
lsr.w #3,d0 ;###lsr.w #4,d2
mulu #40,d1
add.w d0,d1
move.l d1,d5 ;d5 = XYadr.
move.l tegn_data,a0 ;Beregn
clr.l d0 ;tegn adr.
move.b tegn_nr,d0
mulu #14,d0 ;##32
add.l d0,a0 ;Tegn adr.(Sourse)
move.l #bitplanes,a1
move.b tegn_farve,d0
move.w #0,d1 ;(Til loop)###5,
tegn2: move.w d2,d3 ;(Shift)
btst d1,d0 ;Check farve
beq tegn1 ;Bplan = 0 ?
add.w #$bfa,d3 ;hvis nej,...
bra tegn3
tegn1: add.w #$f0a,d3 ;Hvis ja,...
tegn3: jsr tegn_blit
add.w #1,d1 ;###sub.w
cmp.w #5,d1
bne tegn2 ;Loop
rts
tegn_blit:
tegn4: btst #14,$dff002 ;Blitter klar ?
bne tegn4 ;Nej, loop.
move.l (a1)+,d4 ;Hent BPlan
add.l d5,d4 ;+ XYadr.
move.l a0,$dff050 ;Sourse A
move.l d4,$dff048 ; - C
move.l d4,$dff054 ;Destination
move.w #-2,$dff064 ;Modulo A
move.w #36,$dff060 ; - C
move.w #36,$dff066 ;Modulo D
move.w #$ffff,$dff044 ;First Mask
move.w #0,$dff046 ;Last Mask
move.w d3,$dff040 ;Control 0
move.w #0,$dff042 ; - 1
move.w #450,$dff058 ;Size
rts
;DATA
tegn_data: dc.l 0
tegn_X: dc.w 100
tegn_Y: dc.w 100
tegn_nr: dc.b 9
tegn_farve: dc.b 9
align 4
;******* Clear Screen ********
clear_screen:
clr.l d0
move.l #bitplanes,a0
move.w #5,d1
clear1: move.l (a0)+,a1
move.w #2000,d2
clear2: move.l d0,(a1)+
sub.w #1,d2
bne clear2
sub.w #1,d1
bne clear1
rts
;*********************************
;* SEA MUSIC *
;*********************************
opstart:
move.b #0,$bfe400
move.b #254,$bfe500
move.b #9,$bfee01
move.b #255,$bfe500
move.l #startA,nypointer1A
move.l #startA,datapointerA
stop: rts
;**** START MUSIC ******************
music: cmp.b #1,stopcheck
beq music1
rts
music1: cmp.b #255,$bfe501
beq check
rts
check: move.b #254,$bfe500
move.b #25,$bfee01
move.b #255,$bfe500
cmp.b #1,pauseA
beq dataA
sub.b #1,pauseA
rts
;**** Audio data for kanal 0 *********
dataA: move.w #1,$dff096 ;stop sound
move.l datapointerA,a0
move.b (a0),pauseA ;pause taeller
cmp.b #251,pauseA
beq stop
add.l #1,a0 ;+ datapointerA
clr.l d0
move.b (a0),d0 ;soundcode
mulu #4,d0
move.l d0,a2
move.l #sound0,a1
move.l (a2,a1),$dff0a0 ;start adr.
move.l #length0,a1
move.w (a2,a1),$dff0a4 ;laengde
add.l #1,a0 ;+ datapointerA
move.w (a0),$dff0a6 ;freq
add.l #2,a0 ;+ datapointerA
move.b (a0),$dff0a8 ;vol.
add.l #2,a0 ;+ datapointerA
move.l a0,d0
move.l d0,datapointerA
move.w #300,d0
qebd: dbeq d0,qebd ;pause
move.w #33281,$dff096 ;start sound
move.w #1,$dff0a4 ;laengde
rts
;**** VARIABLER TIL SEA MUSIC ******
nypointer1A: dc.l 0
datapointerA: dc.l 0
soundcodeA: dc.b 0
pauseA: dc.b 1
stopcheck: dc.b 0
align 4
;**** DATA TIL SEA MUSIC ***********
startA:
dc.b 9,10,1,173,20,0, 6,10,1,173,20,0
dc.b 3,10,1,173,15,0, 6,10,1,105,20,0
dc.b 3,10,1,173,20,0, 3,10,1,173,15,0
dc.b 6,10,1,173,20,0, 3,10,1,105,20,0
dc.b 9,10,1,105,15,0
dc.b 9,10,1,173,20,0, 6,10,1,173,20,0
dc.b 3,10,1,173,15,0, 6,10,1,105,20,0
dc.b 1,10,1,173,20,0, 1,10,1,173,20,0
dc.b 7,10,1,173,20,0, 6,10,1,173,20,0
dc.b 3,10,1,173,15,0, 6,10,1,105,20,0
dc.b 9,10,1,173,20,0, 6,10,1,173,20,0
dc.b 3,10,1,173,20,0, 6,10,1,105,20,0
dc.b 3,10,1,173,20,0, 3,10,1,173,20,0
dc.b 3,10,1,173,20,0, 6,10,1,173,20,0
dc.b 3,10,1,105,15,0, 6,10,1,105,20,0
dc.b 1,10,1,105,20,0, 1,10,1,105,20,0
dc.b 7,10,1,105,20,0, 1,10,1,105,20,0
dc.b 1,10,1,105,20,0, 13,10,1,105,20,0
dc.b 9,10,1,173,20,0, 6,10,1,173,20,0
dc.b 3,10,1,173,15,0, 6,10,1,105,20,0
dc.b 3,10,1,173,20,0, 6,10,1,173,20,0
dc.b 3,10,1,173,15,0, 12,10,1,105,20,0
dc.b 1,10,1,773,20,0, 1,10,1,173,20,0
dc.b 7,10,1,173,20,0, 1,10,1,173,20,0
dc.b 1,10,1,173,20,0, 13,10,1,173,20,0
dc.b 9,10,1,173,20,0, 6,10,1,173,20,0
dc.b 3,10,1,173,15,0, 6,10,1,173,20,0
dc.b 9,10,1,173,20,0, 6,10,1,173,20,0
dc.b 3,10,1,173,15,0, 6,10,1,173,20,0
dc.b 251